<%= stylesheet_link_tag "playlists/_index" %>
<%= stylesheet_link_tag "mine/_playlist_fav" %>

<script type="text/javascript" charset="utf-8">
    $(function () {
        var minePlaylistFav = root.getWidgetById('mine_playlist_fav');

        minePlaylistFav.on('keydown', function (e) {
            e =e || window.event;
            var keyValue = e.which || e.keyCode;
            if (keyValue === 13) {
                window.location.href = e.target.con.dataset.href
            }
        });
    });
</script>

<div id="mine_playlist_fav" class="playlist-scroll-v" fe-role="Scroll" fe-cfg="scroll_dir:v,">
  <div class="scroll-list">

    <% items.each do |row| %>
      <div class="playlist-scroll-h" fe-role="Scroll"
           fe-cfg="scroll_dir:h,scroll_duration:0.3,scroll_easing:ease-out">
        <ul class="scroll-list clearfix" style="width: <%= row.size * 215 + 100 %>px;">

          <% row.each_with_index do |item, index| %>
            <li data-href="<%= item_href_url(item) %>" class="playlist-tab"
                fe-role="Widget"
                fe-cfg="<%= "default_focus:yes," if index === 0 %>"
            >

              <div class="playlist-tab-photo">
                <div class="photo-mask"></div>
                <%= image_tag("icons/播放_play.png", class: "play-icon") %>
                <%= image_tag(item_image_url(item), class: "playlist-tab-photo-img", onerror: "this.onerror=null;this.src='/singer_default.jpg';") %>
              </div>

              <div class="playlist-tab-outer">
                <div class="marquee-truncate overflow-hidden"><%= item[:name] %></div>
              </div>

            </li>
          <% end %>

        </ul>
      </div>
    <% end %>

  </div>
</div>
